import pandas as pd
import numpy as np
date="""toDate('2021/12/09')"""
data_count=500

gender=["\"男\"","\"女\""]
iden_type=["\"身份证\"","\"港澳台通行证\""]
type=["\"1\"","\"2\"","\"3\"","\"4\"","\"5\"","\"6\"","\"7\"","\"8\"","\"9\""]

#('2021-12-09',100001,'男','上海市长宁区愚园路000001',22,'身份证','153464000001','1','A','3','1','DA',
data = pd.DataFrame(
    {
         "data_dt":date
       ,"cust_id":np.random.randint(100000,200000,data_count)
       ,"gender":[gender[x] for x in np.random.randint(0,2,data_count)]
       ,"address":["\"上海市长宁区愚园路" + str(x) + "\"" for x in np.random.randint(100,20000,data_count)]
       ,"age":np.random.randint(10,99,data_count)
       ,"iden_type":[iden_type[x] for x in np.random.randint(0,2,data_count)]
       ,"iden_no":[type[x] for x in np.random.randint(0,9,data_count)]
       ,"Educationdegree":[type[x] for x in np.random.randint(0,9,data_count)]
       ,"Academicdegree":[type[x] for x in np.random.randint(0,9,data_count)]
       ,"Employertype":[type[x] for x in np.random.randint(0,9,data_count)]
       ,"Addrregion":[type[x] for x in np.random.randint(0,9,data_count)]
       ,"Occupationtype":[type[x] for x in np.random.randint(0,9,data_count)]
       ,"O1__CR_LGST_ODUE_MONUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O1__CR_LN_ODUE_MO_NUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O1__CRLNODUEBLMHTODUETAMT_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O2__ACC_NUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O2__CR_LGST_ODUE_MONUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O2__CR_LN_ODUE_MO_NUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O2__CRLNODUEBLMHTODUETAMT_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O3__ACC_NUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O3__CR_LGST_ODUE_MONUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O3__CR_LN_ODUE_MO_NUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O3__CRLNODUEBLMHTODUETAMT_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O4__ACC_NUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O4__CR_LGST_ODUE_MONUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O4__CR_LN_ODUE_MO_NUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O4__CRLNODUEBLMHTODUETAMT_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O5__ACC_NUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O5__CR_LGST_ODUE_MONUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O5__CR_LN_ODUE_MO_NUM_Sum":np.random.randint(-1000000,2000000,data_count)
       ,"O5__CRLNODUEBLMHTODUETAMT_Sum":np.random.randint(-1000000,2000000,data_count)


    }
)
#print(data)
#print(data.dtypes)

print(data.to_csv('a.csv',index=False))

